


import java.awt.Color;
import java.awt.Font;
import java.awt.Insets;
import javax.swing.*;

/**
 * Top panel with add event and filter button. Also displays current month and
 * year.
 */
public class BottomPanel extends ObservingJPanel {
    
    protected JButton pinchIn;
    protected JButton pinchOut;
    protected JButton slideLeft;
    protected JButton slideRight;
    
    protected CalendarController controller;
    
    public BottomPanel(CalendarController controller) {
        this.controller = controller;
        
        this.setBackground(new Color(133,133,133));
        
        pinchIn = new JButton("Pinch in");
		pinchOut = new JButton("Pinch out");
        slideLeft = new JButton("Slide left");
        slideRight = new JButton("Slide right");
        
        Font font = new Font("Verdana", Font.PLAIN, 10);
        pinchIn.setFont(font);
        pinchOut.setFont(font);
        slideLeft.setFont(font);
        slideRight.setFont(font);
        
        Insets insets = new Insets(0, 0, 0, 0);
        pinchIn.setMargin(insets);
        pinchOut.setMargin(insets);
        slideLeft.setMargin(insets);
        slideRight.setMargin(insets);
        
        // Add listeners
        pinchIn.addActionListener(controller.createPinchInListener());
        pinchOut.addActionListener(controller.createPinchOutListener());
        slideLeft.addActionListener(controller.createSlideLeftListener());
        slideRight.addActionListener(controller.createSlideRightListener());
		
        this.add(pinchIn);
        this.add(pinchOut);
        this.add(slideLeft);
        this.add(slideRight);
    }

    @Override
    public void update() {
        throw new UnsupportedOperationException("Not supported yet.");
    }
    
}
